#include<stdio.h>

int missingNumber(int* nums, int numsSize) {
    int num = 0;
    int j = 0;
    for (int i = 0; i <= numsSize; i++)
    {
        num ^= i;
    }
    for (int i = 0; i < numsSize; i++)
    {
        num ^= nums[i];
    }
    return num;
}
